fix(deploy): add CORS origins env var to API deployment#451
Conversation
The ConfigMap had the CORS origins but the API deployment never read the key — it was missing from the container's env spec. OPTIONS preflight requests returned 405 because the CORS middleware was never initialized. Marked optional so local/dev deployments without CORS config still work (CORS disabled by default when origins list is empty). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
Caution Review failedPull request was closed or merged during review No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Enterprise Run ID: 📒 Files selected for processing (1)
WalkthroughA new environment variable Estimated code review effort🎯 1 (Trivial) | ⏱️ ~2 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
) The ConfigMap had the CORS origins but the API deployment never read the key — it was missing from the container's env spec. OPTIONS preflight requests returned 405 because the CORS middleware was never initialized. Marked optional so local/dev deployments without CORS config still work (CORS disabled by default when origins list is empty). Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
) The ConfigMap had the CORS origins but the API deployment never read the key — it was missing from the container's env spec. OPTIONS preflight requests returned 405 because the CORS middleware was never initialized. Marked optional so local/dev deployments without CORS config still work (CORS disabled by default when origins list is empty). Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Summary
The CORS origins were in the ConfigMap but the API deployment never read the key —
KARTOGRAPH_CORS_ORIGINSwas missing from the container's env spec. The CORS middleware never initialized, causing OPTIONS preflight requests to return 405.Adds
configMapKeyRefforKARTOGRAPH_CORS_ORIGINSwithoptional: trueso deployments without CORS config still work.🤖 Generated with Claude Code
Summary by CodeRabbit